# Create your views here.

from django.shortcuts import render_to_response
from petra.rsdownloads.models import *

from petra.settings import MEDIA_ROOT

def index(request):
	downloads = dict()
	#downloads["downloads"] = Download.objects.order_by("-priority", "start_date")[:10]
	downloads["active_downloads"] = Download.LatestsDownloads()
	downloads["finished_downloads"] = Download.LatestsFinishedDownloads()
	return render_to_response('index.html', downloads)
